/**
 * Copyright &copy; 2015-2020 <a href="http://www.easyhis.com/">easyhis</a> All rights reserved.
 */
package com.easy.dfcapi.entity;

import com.easy.common.utils.excel.annotation.ExcelField;
import com.easy.core.persistence.BaseEntity;
import com.easy.modules.sys.entity.User;

import javax.validation.constraints.NotNull;

/**
 * 用户好友Entity
 * @author waylen chi
 * @version 2018-01-12
 */
public class ApiUserFriend extends BaseEntity<ApiUserFriend> {
	
	private static final long serialVersionUID = 1L;
	private ApiUser user;		// 用户ID
	private ApiUser friend;		// 朋友的用户ID
	private ApiUserGroup group;		// 分组ID
	private String friendName;		// 备注名
	private Integer isBlack = 0;//是否黑名单
	
	public ApiUserFriend() {
		super();
	}


	@NotNull(message="用户ID不能为空")
	@ExcelField(title="用户ID", fieldType=User.class, value=".userName", align=2, sort=0)
	public ApiUser getUser() {
		return user;
	}

	public void setUser(ApiUser user) {
		this.user = user;
	}
	
	@NotNull(message="朋友的用户ID不能为空")
	@ExcelField(title="朋友的用户ID", align=2, sort=1)
	public ApiUser getFriend() {
		return friend;
	}

	public void setFriend(ApiUser friend) {
		this.friend = friend;
	}
	
	@ExcelField(title="分组ID", align=2, sort=2)
	public ApiUserGroup getGroup() {
		return group;
	}

	public void setGroup(ApiUserGroup group) {
		this.group = group;
	}
	
	@ExcelField(title="备注名", align=2, sort=3)
	public String getFriendName() {
		return friendName;
	}

	public void setFriendName(String friendName) {
		this.friendName = friendName;
	}

	public Integer getIsBlack() {
		return isBlack;
	}

	public void setIsBlack(Integer isBlack) {
		this.isBlack = isBlack;
	}
}